Update Document Type
PUT : http://<base_url>/digipay/v3/user/document_type
This API is used to update new document type into the system
BODY PARAMS:-
Parameter | Type | Description | Value |
---|---|---|---|
id | String | Unique id assign to document retrive a document type detail. | da65da5sd6a5dsa56d |
document_type_title | String | The title or name of the document type, such as ""Passport"" or ""Driver's License. | selfish |
document_user_type | Int | Represents the user type associated with the document, like different roles or permissions | 2 |
document_side_type | Int | Denotes the type of document side (front, back, both) that is being referred to. | 1 |
is_mandatory | Boolean | A boolean flag indicating whether the document is mandatory. | true/false |
document_extra_fields | Array of Strings | An array of additional fields or information related to the document. | "business_types": ["[\"\"type1\"\"","\"\"type2\"\"]"] |
document_type | Int | Represents the type or classification of the document. | 1 |
document_category | Int | Denotes the category to which the document belongs. | 2 |
dynamic_category_key | String | A key that dynamically links documents to specific categories. | dynamic_key |
business_types | Array of Strings | A list of business types associated with the document. | [ |
"[\"\"type1\"\"",
"\"\"type2\"\"]"
] |
| expiry_date_required | Boolean | A boolean flag indicating whether an expiry date is required for the document."| true/false |
HEADERS:-
Parameter | Type | Description | Value |
---|---|---|---|
Authorization | String | It is a combination of type and token to authenticate user for the given token | Token duik7309njdlkhdauhknksadhjkas986876sd873j |
CompanyID | String | Company_id is a unique primary id, that is represent company detail | 76bc712200ca444fa334f9e55e5fd7a8 |
Request Body:-
Request Example
curl --request PUT \
--url http://192.168.1.102:8014/digipay/v3/user/document_type \
--header 'Authorization: Token eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJzdWIiOiI2NWY0ZDI1MDliZmU0NTBmYTg4MTVhNTU5Njk3YmM0NyIsInJvbGVzIjpbIlJPTEVfQURNSU4iXSwiZXhwIjoxNjkzNTIxOTU1fQ.9oWwUzlFzmYB1ZOhaVamxKJH6DsMO8tFue2kbg2YyoI' \
--header 'CompanyID: 76bc712200ca444fa334f9e55e5fd7a8' \
--header 'accept: application/json' \
--header 'content-type: application/json' \
--data '
{
"id": "da65da5sd6a5dsa56d",
"document_type_title": "selfish",
"document_user_type": 2,
"document_side_type": 1,
"is_mandatory": false,
"document_extra_fields": [
"[\"\"field1\"\"",
"\"\"field2\"\"]"
],
"document_type": 2,
"document_category": 2,
"dynamic_category_key": "dynamic_key",
"business_types": [
"[\"\"type1\"\"",
"\"\"type2\"\"]"
],
"expiry_date_required": false
}
'
Response:-
Response 200(OK)
{
"success": 1,
"error": [],
"data": {
"message": "Document type detail updated successfully."
}
}
Response 400(BAD REQUEST)
{
"success": 0,
"error"": [1],
"data": {
"message": "BAD_REQUEST",
}
}
RESPONSES :-
Status Code | Description |
---|---|
200 | OK |
400 | Bad Request |
404 | Not Found |
500 | Internal Server Error |